package dapps.entity.monitor;

import java.util.ArrayList;
import java.util.List;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Transient;

import org.hibernate.annotations.Cache;
import org.hibernate.annotations.CacheConcurrencyStrategy;

@Entity
@Table(name = "servicedata")
@Cache(usage = CacheConcurrencyStrategy.READ_WRITE)
public class Servicedata {

	public Servicedata() {

	}
	
	@Id
	@Column(nullable=false,unique=true)
	private Long mainid;
	
	
	
	//2
	private Double fixedassetsinvestlm;
	private Double fixedassetsinvestlmper;
	private Double fixedassetsinvestsum;
	private Double fixedassetsinvestsumper;
	
	private Integer newproject;
	private String newindustry;
	
	private Integer outinvest;
	private Double outinvestamount;
	private String outinvestregion;
	
	//3
	private Double netassets;
	private Long employer;
	private Double receivables;
	private Double payables;
	private Double bizarea;
	private Integer bizdot;
	private Double electricity;
	private Double water;
	private Integer newemployer;
	
	private Double allincomelm;
	private Double allincomelmsum;
	private Double allincomelysum;
	
	private Double mincomelm;
	private Double mincomelmsum;
	private Double mincomelysum;
	
	private Double costlm;
	private Double costlmsum;
	private Double costlysum;
	
	private Double profitlm;
	private Double profitlmsum;
	private Double profitlysum;
	
	private Double profitaftaxlm;
	private Double profitaftaxlmsum;
	private Double profitaftaxlysum;	
	
	
	
	@Column(length = 500)
	private String problem;
	
	@Column(length = 500)
	private String advice;

	public Long getMainid() {
		return mainid;
	}

	public void setMainid(Long mainid) {
		this.mainid = mainid;
	}

	public Double getFixedassetsinvestlm() {
		return fixedassetsinvestlm;
	}

	public void setFixedassetsinvestlm(Double fixedassetsinvestlm) {
		this.fixedassetsinvestlm = fixedassetsinvestlm;
	}

	public Double getFixedassetsinvestlmper() {
		return fixedassetsinvestlmper;
	}

	public void setFixedassetsinvestlmper(Double fixedassetsinvestlmper) {
		this.fixedassetsinvestlmper = fixedassetsinvestlmper;
	}

	public Double getFixedassetsinvestsum() {
		return fixedassetsinvestsum;
	}

	public void setFixedassetsinvestsum(Double fixedassetsinvestsum) {
		this.fixedassetsinvestsum = fixedassetsinvestsum;
	}

	public Double getFixedassetsinvestsumper() {
		return fixedassetsinvestsumper;
	}

	public void setFixedassetsinvestsumper(Double fixedassetsinvestsumper) {
		this.fixedassetsinvestsumper = fixedassetsinvestsumper;
	}

	public Integer getNewproject() {
		return newproject;
	}

	public void setNewproject(Integer newproject) {
		this.newproject = newproject;
	}

	public String getNewindustry() {
		return newindustry;
	}

	public void setNewindustry(String newindustry) {
		this.newindustry = newindustry;
	}

	public Integer getOutinvest() {
		return outinvest;
	}

	public void setOutinvest(Integer outinvest) {
		this.outinvest = outinvest;
	}

	public Double getOutinvestamount() {
		return outinvestamount;
	}

	public void setOutinvestamount(Double outinvestamount) {
		this.outinvestamount = outinvestamount;
	}

	public String getOutinvestregion() {
		return outinvestregion;
	}

	public void setOutinvestregion(String outinvestregion) {
		this.outinvestregion = outinvestregion;
	}

	public Double getNetassets() {
		return netassets;
	}

	public void setNetassets(Double netassets) {
		this.netassets = netassets;
	}

	public Long getEmployer() {
		return employer;
	}

	public void setEmployer(Long employer) {
		this.employer = employer;
	}

	public Double getReceivables() {
		return receivables;
	}

	public void setReceivables(Double receivables) {
		this.receivables = receivables;
	}

	public Double getPayables() {
		return payables;
	}

	public void setPayables(Double payables) {
		this.payables = payables;
	}

	public Double getBizarea() {
		return bizarea;
	}

	public void setBizarea(Double bizarea) {
		this.bizarea = bizarea;
	}

	public Integer getBizdot() {
		return bizdot;
	}

	public void setBizdot(Integer bizdot) {
		this.bizdot = bizdot;
	}

	public Double getElectricity() {
		return electricity;
	}

	public void setElectricity(Double electricity) {
		this.electricity = electricity;
	}



	public Double getWater() {
		return water;
	}

	public void setWater(Double water) {
		this.water = water;
	}

	public Integer getNewemployer() {
		return newemployer;
	}

	public void setNewemployer(Integer newemployer) {
		this.newemployer = newemployer;
	}

	public Double getAllincomelm() {
		return allincomelm;
	}

	public void setAllincomelm(Double allincomelm) {
		this.allincomelm = allincomelm;
	}

	public Double getAllincomelmsum() {
		return allincomelmsum;
	}

	public void setAllincomelmsum(Double allincomelmsum) {
		this.allincomelmsum = allincomelmsum;
	}

	public Double getAllincomelysum() {
		return allincomelysum;
	}

	public void setAllincomelysum(Double allincomelysum) {
		this.allincomelysum = allincomelysum;
	}

	public Double getMincomelm() {
		return mincomelm;
	}

	public void setMincomelm(Double mincomelm) {
		this.mincomelm = mincomelm;
	}

	public Double getMincomelmsum() {
		return mincomelmsum;
	}

	public void setMincomelmsum(Double mincomelmsum) {
		this.mincomelmsum = mincomelmsum;
	}

	public Double getMincomelysum() {
		return mincomelysum;
	}

	public void setMincomelysum(Double mincomelysum) {
		this.mincomelysum = mincomelysum;
	}

	public Double getCostlm() {
		return costlm;
	}

	public void setCostlm(Double costlm) {
		this.costlm = costlm;
	}

	public Double getCostlmsum() {
		return costlmsum;
	}

	public void setCostlmsum(Double costlmsum) {
		this.costlmsum = costlmsum;
	}

	public Double getCostlysum() {
		return costlysum;
	}

	public void setCostlysum(Double costlysum) {
		this.costlysum = costlysum;
	}

	public Double getProfitlm() {
		return profitlm;
	}

	public void setProfitlm(Double profitlm) {
		this.profitlm = profitlm;
	}

	public Double getProfitlmsum() {
		return profitlmsum;
	}

	public void setProfitlmsum(Double profitlmsum) {
		this.profitlmsum = profitlmsum;
	}

	public Double getProfitlysum() {
		return profitlysum;
	}

	public void setProfitlysum(Double profitlysum) {
		this.profitlysum = profitlysum;
	}

	public Double getProfitaftaxlm() {
		return profitaftaxlm;
	}

	public void setProfitaftaxlm(Double profitaftaxlm) {
		this.profitaftaxlm = profitaftaxlm;
	}

	public Double getProfitaftaxlmsum() {
		return profitaftaxlmsum;
	}

	public void setProfitaftaxlmsum(Double profitaftaxlmsum) {
		this.profitaftaxlmsum = profitaftaxlmsum;
	}

	public Double getProfitaftaxlysum() {
		return profitaftaxlysum;
	}

	public void setProfitaftaxlysum(Double profitaftaxlysum) {
		this.profitaftaxlysum = profitaftaxlysum;
	}

	public String getProblem() {
		return problem;
	}

	public void setProblem(String problem) {
		this.problem = problem;
	}

	public String getAdvice() {
		return advice;
	}

	public void setAdvice(String advice) {
		this.advice = advice;
	}
	@Transient
	public List<String[]> getFields(){
		String[] fieldstr1 = {"1","newproject","outinvest"};//count
		String[] fieldstr2 = {"2","netassets","employer","receivables","payables","bizarea","bizdot",
				"electricity","water","newemployer",
				"allincomelm","allincomelmsum","allincomelysum",
				"mincomelm","mincomelmsum","mincomelysum",
				"costlm","costlmsum","costlysum",
				"profitlm","profitlmsum","profitlysum",
				"profitaftaxlm","profitaftaxlmsum","profitaftaxlysum"};//sum
		String[] fieldstr3 = {"3","netassets","employer","receivables","payables","bizarea","bizdot"};//month 环比		
		List<String[]> ls = new ArrayList<String[]> ();
		ls.add(fieldstr1);ls.add(fieldstr2);ls.add(fieldstr3);
		return ls;
		
	}
	@Transient
	public List<String[]> getlastmonthFields(){
		String[] fieldstr3 = {"3","netassets","employer","receivables","payables","bizarea","bizdot"};//month 环比		
		List<String[]> ls = new ArrayList<String[]> ();
		ls.add(fieldstr3);
		return ls;
		
	}
	@Override
	public String toString() {
		return this.getMainid().toString();
	}

}
